package thread;

class  MyThread3 extends  Thread{

    @Override
    public void run() {
        System.out.println("name:"+this.getName()+"id::"+this.getId());
    }
}

public class ThreadDemo13 {
    public static void main(String[] args) throws InterruptedException {
        Thread t1=new MyThread3();
        Thread t2=new MyThread3();
        t1.start();
        t2.start();
        Thread.sleep(1000);
        System.out.println("t1.name"+t1.getName()+"t1.id"+t1.getId());
        System.out.println("t2.name:"+t2.getName()+"t2.id:"+t2.getId());

    }
}
